<template>
  <div class="manual-upload">
    <div>
      <e-upload
        multiple
        :before-upload="handleUpload"
        action="//jsonplaceholder.typicode.com/posts/">
        <e-button>选择文件</e-button>
      </e-upload>
    </div>
    <div class="upload-click">
      <e-button
        icon="sq-upload"
        @click="upload"
        type="primary">
        上传
      </e-button>
    </div>
  </div>
</template>

<script setup>
import { ref, getCurrentInstance } from 'vue';

const file = ref(null)
const { proxy } = getCurrentInstance();
const handleUpload = (file) => {
  return true
}
const upload = () => {
  setTimeout(() => {
    proxy.$Message.success('Success')
  }, 1500)
}
</script>

<style>
  .manual-upload{
    display: flex;
    position: relative;
  }
   .upload-click{
     position: absolute;
     left: 88px;
   }
</style>
